package com.saku.uiprojecttest.components;/**
 * Created by liumin on 2017/2/27.
 */


import com.saku.uiprojecttest.SakuApplication;
import com.saku.uiprojecttest.http.NetManager;
import com.saku.uiprojecttest.modules.ApiModule;
import com.saku.uiprojecttest.modules.AppModule;
import com.saku.uiprojecttest.modules.SakuNetModule;

import javax.inject.Singleton;

import dagger.Component;

/**
 * User: Missa
 * Date: 2017-02-27
 * Time: 21:52
 * Description:
 */

@Singleton
@Component(modules = {ApiModule.class, AppModule.class, SakuNetModule.class})
public interface SakuComponent extends ISakuComp{

    final class Initializer {
        private Initializer() {}

        public static SakuComponent init(SakuApplication application) {
            return DaggerSakuComponent.builder()
                    .apiModule(new ApiModule())
                    .appModule(new AppModule())
                    .sakuNetModule(new SakuNetModule())
                    .build();
        }
    }
    NetManager getNetManager();

}
